const parser = require('@babel/parser')

const code = `
  const square = x => x ** 2
  const sum = a => a + 2
  const list = 5 |> aquare(^^) |> sum(^^);

`

const ast = parser.parse(code,{
  sourceType:'module',
  plugins:[
    ['pipelineOperator',{
      proposal: 'hack',
      topicToken: '^^'
    }]
  ]
})

console.log(ast.program.body)